pub fn convert_base(num_str: &str, to_base: u32) -> String {
    let num: String = num_str.split('(').collect::<Vec<&str>>()[0].to_string();
    let base = num_str.split('(').collect::<Vec<&str>>()[1]
        .split(')')
        .collect::<Vec<&str>>()[0]
        .parse::<u32>()
        .unwrap();
    let mut num_base_10 = u32::from_str_radix(&num, base).unwrap();
    let mut res = String::new();
    while num_base_10 > 0 {
        let rem = num_base_10 % to_base;
        let rem_char = if rem < 10 {
            (rem as u8 + b'0') as char
        } else {
            (rem - 10 + 'a' as u32) as u8 as char
        };
        res.push(rem_char);
        num_base_10 /= to_base;
    }
    res.chars().rev().collect()
}
